/**
 * ajaxform相关js
 */

function showFileName(file){
	  var url=file.value.split("\\");//用转义的"\\"来处理
	  $(file).parent().find("span").text("文件:"+url[url.length-1]);
  }
  

function ajaxUpload(formId){
	alert(formId);
	appLoading("正在上传...");
	$("#"+formId).ajaxSubmit({
		type:"post",
		url:"upload/"+formId,
		dataType:"json",
		success:function(data){
			JsonConsoleProcess(data);
		}
	});
}

$(function() {
//	alert("我在uplodify");
	$("#uplodifyFile").uploadify({
		height        : 30,
		swf           : 'static/other/uploadify.swf',
		uploader      : 'uplodify',
		width         : 120,
		onUploadSuccess : function(file, data, response) {
			JsonConsoleProcess(eval("("+data+")"));
        }
	});
});